package ext.tianma.model;

@SuppressWarnings({"cast", "deprecation", "unchecked"})
public abstract class _FormDataXml extends wt.fc.WTObject implements java.io.Externalizable {
   static final long serialVersionUID = 1;

   static final java.lang.String RESOURCE = "ext.tianma.model.modelResource";
   static final java.lang.String CLASSNAME = FormDataXml.class.getName();

   /**
    * 流程对象
    *
    * @see ext.tianma.model.FormDataXml
    */
   public static final java.lang.String PROCESS = "process";
   wt.fc.ObjectReference process;
   /**
    * 流程对象
    *
    * @see ext.tianma.model.FormDataXml
    */
   public wt.fc.ObjectReference getProcess() {
      return process;
   }
   /**
    * 流程对象
    *
    * @see ext.tianma.model.FormDataXml
    */
   public void setProcess(wt.fc.ObjectReference process) throws wt.util.WTPropertyVetoException {
      processValidate(process);
      this.process = process;
   }
   void processValidate(wt.fc.ObjectReference process) throws wt.util.WTPropertyVetoException {
   }

   /**
    * 主对象
    *
    * @see ext.tianma.model.FormDataXml
    */
   public static final java.lang.String PERSISTABLE = "persistable";
   wt.fc.ObjectReference persistable;
   /**
    * 主对象
    *
    * @see ext.tianma.model.FormDataXml
    */
   public wt.fc.ObjectReference getPersistable() {
      return persistable;
   }
   /**
    * 主对象
    *
    * @see ext.tianma.model.FormDataXml
    */
   public void setPersistable(wt.fc.ObjectReference persistable) throws wt.util.WTPropertyVetoException {
      persistableValidate(persistable);
      this.persistable = persistable;
   }
   void persistableValidate(wt.fc.ObjectReference persistable) throws wt.util.WTPropertyVetoException {
   }

   /**
    * 流程状态
    *
    * @see ext.tianma.model.FormDataXml
    */
   public static final java.lang.String STATUS = "status";
   static int STATUS_UPPER_LIMIT = -1;
   java.lang.String status;
   /**
    * 流程状态
    *
    * @see ext.tianma.model.FormDataXml
    */
   public java.lang.String getStatus() {
      return status;
   }
   /**
    * 流程状态
    *
    * @see ext.tianma.model.FormDataXml
    */
   public void setStatus(java.lang.String status) throws wt.util.WTPropertyVetoException {
      statusValidate(status);
      this.status = status;
   }
   void statusValidate(java.lang.String status) throws wt.util.WTPropertyVetoException {
      if (STATUS_UPPER_LIMIT < 1) {
         try { STATUS_UPPER_LIMIT = (java.lang.Integer) wt.introspection.WTIntrospector.getClassInfo(CLASSNAME).getPropertyDescriptor("status").getValue(wt.introspection.WTIntrospector.UPPER_LIMIT); }
         catch (wt.introspection.WTIntrospectionException e) { STATUS_UPPER_LIMIT = 300; }
      }
      if (status != null && !wt.fc.PersistenceHelper.checkStoredLength(status.toString(), STATUS_UPPER_LIMIT, true))
         throw new wt.util.WTPropertyVetoException("wt.introspection.introspectionResource", wt.introspection.introspectionResource.UPPER_LIMIT,
               new java.lang.Object[] { new wt.introspection.PropertyDisplayName(CLASSNAME, "status"), java.lang.String.valueOf(java.lang.Math.min(STATUS_UPPER_LIMIT, wt.fc.PersistenceHelper.DB_MAX_SQL_STRING_SIZE/wt.fc.PersistenceHelper.DB_MAX_BYTES_PER_CHAR)) },
               new java.beans.PropertyChangeEvent(this, "status", this.status, status));
   }

   /**
    * 表单信息
    *
    * @see ext.tianma.model.FormDataXml
    */
   public static final java.lang.String FORMCONTENT = "formcontent";
   java.sql.Blob formcontent;
   /**
    * 表单信息
    *
    * @see ext.tianma.model.FormDataXml
    */
   public java.sql.Blob getFormcontent() {
      return formcontent;
   }
   /**
    * 表单信息
    *
    * @see ext.tianma.model.FormDataXml
    */
   public void setFormcontent(java.sql.Blob formcontent) throws wt.util.WTPropertyVetoException {
      formcontentValidate(formcontent);
      this.formcontent = formcontent;
   }
   void formcontentValidate(java.sql.Blob formcontent) throws wt.util.WTPropertyVetoException {
   }

   /**
    * 预留字段1
    *
    * @see ext.tianma.model.FormDataXml
    */
   public static final java.lang.String TEMP_COLUMN1 = "tempColumn1";
   static int TEMP_COLUMN1_UPPER_LIMIT = -1;
   java.lang.String tempColumn1;
   /**
    * 预留字段1
    *
    * @see ext.tianma.model.FormDataXml
    */
   public java.lang.String getTempColumn1() {
      return tempColumn1;
   }
   /**
    * 预留字段1
    *
    * @see ext.tianma.model.FormDataXml
    */
   public void setTempColumn1(java.lang.String tempColumn1) throws wt.util.WTPropertyVetoException {
      tempColumn1Validate(tempColumn1);
      this.tempColumn1 = tempColumn1;
   }
   void tempColumn1Validate(java.lang.String tempColumn1) throws wt.util.WTPropertyVetoException {
      if (TEMP_COLUMN1_UPPER_LIMIT < 1) {
         try { TEMP_COLUMN1_UPPER_LIMIT = (java.lang.Integer) wt.introspection.WTIntrospector.getClassInfo(CLASSNAME).getPropertyDescriptor("tempColumn1").getValue(wt.introspection.WTIntrospector.UPPER_LIMIT); }
         catch (wt.introspection.WTIntrospectionException e) { TEMP_COLUMN1_UPPER_LIMIT = 300; }
      }
      if (tempColumn1 != null && !wt.fc.PersistenceHelper.checkStoredLength(tempColumn1.toString(), TEMP_COLUMN1_UPPER_LIMIT, true))
         throw new wt.util.WTPropertyVetoException("wt.introspection.introspectionResource", wt.introspection.introspectionResource.UPPER_LIMIT,
               new java.lang.Object[] { new wt.introspection.PropertyDisplayName(CLASSNAME, "tempColumn1"), java.lang.String.valueOf(java.lang.Math.min(TEMP_COLUMN1_UPPER_LIMIT, wt.fc.PersistenceHelper.DB_MAX_SQL_STRING_SIZE/wt.fc.PersistenceHelper.DB_MAX_BYTES_PER_CHAR)) },
               new java.beans.PropertyChangeEvent(this, "tempColumn1", this.tempColumn1, tempColumn1));
   }

   /**
    * 预留字段2
    *
    * @see ext.tianma.model.FormDataXml
    */
   public static final java.lang.String TEMP_COLUMN2 = "tempColumn2";
   static int TEMP_COLUMN2_UPPER_LIMIT = -1;
   java.lang.String tempColumn2;
   /**
    * 预留字段2
    *
    * @see ext.tianma.model.FormDataXml
    */
   public java.lang.String getTempColumn2() {
      return tempColumn2;
   }
   /**
    * 预留字段2
    *
    * @see ext.tianma.model.FormDataXml
    */
   public void setTempColumn2(java.lang.String tempColumn2) throws wt.util.WTPropertyVetoException {
      tempColumn2Validate(tempColumn2);
      this.tempColumn2 = tempColumn2;
   }
   void tempColumn2Validate(java.lang.String tempColumn2) throws wt.util.WTPropertyVetoException {
      if (TEMP_COLUMN2_UPPER_LIMIT < 1) {
         try { TEMP_COLUMN2_UPPER_LIMIT = (java.lang.Integer) wt.introspection.WTIntrospector.getClassInfo(CLASSNAME).getPropertyDescriptor("tempColumn2").getValue(wt.introspection.WTIntrospector.UPPER_LIMIT); }
         catch (wt.introspection.WTIntrospectionException e) { TEMP_COLUMN2_UPPER_LIMIT = 300; }
      }
      if (tempColumn2 != null && !wt.fc.PersistenceHelper.checkStoredLength(tempColumn2.toString(), TEMP_COLUMN2_UPPER_LIMIT, true))
         throw new wt.util.WTPropertyVetoException("wt.introspection.introspectionResource", wt.introspection.introspectionResource.UPPER_LIMIT,
               new java.lang.Object[] { new wt.introspection.PropertyDisplayName(CLASSNAME, "tempColumn2"), java.lang.String.valueOf(java.lang.Math.min(TEMP_COLUMN2_UPPER_LIMIT, wt.fc.PersistenceHelper.DB_MAX_SQL_STRING_SIZE/wt.fc.PersistenceHelper.DB_MAX_BYTES_PER_CHAR)) },
               new java.beans.PropertyChangeEvent(this, "tempColumn2", this.tempColumn2, tempColumn2));
   }

   /**
    * 预留字段3
    *
    * @see ext.tianma.model.FormDataXml
    */
   public static final java.lang.String TEMP_COLUMN3 = "tempColumn3";
   static int TEMP_COLUMN3_UPPER_LIMIT = -1;
   java.lang.String tempColumn3;
   /**
    * 预留字段3
    *
    * @see ext.tianma.model.FormDataXml
    */
   public java.lang.String getTempColumn3() {
      return tempColumn3;
   }
   /**
    * 预留字段3
    *
    * @see ext.tianma.model.FormDataXml
    */
   public void setTempColumn3(java.lang.String tempColumn3) throws wt.util.WTPropertyVetoException {
      tempColumn3Validate(tempColumn3);
      this.tempColumn3 = tempColumn3;
   }
   void tempColumn3Validate(java.lang.String tempColumn3) throws wt.util.WTPropertyVetoException {
      if (TEMP_COLUMN3_UPPER_LIMIT < 1) {
         try { TEMP_COLUMN3_UPPER_LIMIT = (java.lang.Integer) wt.introspection.WTIntrospector.getClassInfo(CLASSNAME).getPropertyDescriptor("tempColumn3").getValue(wt.introspection.WTIntrospector.UPPER_LIMIT); }
         catch (wt.introspection.WTIntrospectionException e) { TEMP_COLUMN3_UPPER_LIMIT = 300; }
      }
      if (tempColumn3 != null && !wt.fc.PersistenceHelper.checkStoredLength(tempColumn3.toString(), TEMP_COLUMN3_UPPER_LIMIT, true))
         throw new wt.util.WTPropertyVetoException("wt.introspection.introspectionResource", wt.introspection.introspectionResource.UPPER_LIMIT,
               new java.lang.Object[] { new wt.introspection.PropertyDisplayName(CLASSNAME, "tempColumn3"), java.lang.String.valueOf(java.lang.Math.min(TEMP_COLUMN3_UPPER_LIMIT, wt.fc.PersistenceHelper.DB_MAX_SQL_STRING_SIZE/wt.fc.PersistenceHelper.DB_MAX_BYTES_PER_CHAR)) },
               new java.beans.PropertyChangeEvent(this, "tempColumn3", this.tempColumn3, tempColumn3));
   }

   public java.lang.String getConceptualClassname() {
      return CLASSNAME;
   }

   public wt.introspection.ClassInfo getClassInfo() throws wt.introspection.WTIntrospectionException {
      return wt.introspection.WTIntrospector.getClassInfo(getConceptualClassname());
   }

   public java.lang.String getType() {
      try { return getClassInfo().getDisplayName(); }
      catch (wt.introspection.WTIntrospectionException wte) { return wt.util.WTStringUtilities.tail(getConceptualClassname(), '.'); }
   }

   public static final long EXTERNALIZATION_VERSION_UID = 6593856020316566837L;

   public void writeExternal(java.io.ObjectOutput output) throws java.io.IOException {
      output.writeLong( EXTERNALIZATION_VERSION_UID );

      super.writeExternal( output );

      output.writeObject( formcontent );
      output.writeObject( persistable );
      output.writeObject( process );
      output.writeObject( status );
      output.writeObject( tempColumn1 );
      output.writeObject( tempColumn2 );
      output.writeObject( tempColumn3 );
   }

   protected void super_writeExternal_FormDataXml(java.io.ObjectOutput output) throws java.io.IOException {
      super.writeExternal(output);
   }

   public void readExternal(java.io.ObjectInput input) throws java.io.IOException, java.lang.ClassNotFoundException {
      long readSerialVersionUID = input.readLong();
      readVersion( (ext.tianma.model.FormDataXml) this, input, readSerialVersionUID, false, false );
   }
   protected void super_readExternal_FormDataXml(java.io.ObjectInput input) throws java.io.IOException, java.lang.ClassNotFoundException {
      super.readExternal(input);
   }

   public void writeExternal(wt.pds.PersistentStoreIfc output) throws java.sql.SQLException, wt.pom.DatastoreException {
      super.writeExternal( output );

      output.setObject( "formcontent", formcontent );
      output.writeObject( "persistable", persistable, wt.fc.ObjectReference.class, true );
      output.writeObject( "process", process, wt.fc.ObjectReference.class, true );
      output.setString( "status", status );
      output.setString( "tempColumn1", tempColumn1 );
      output.setString( "tempColumn2", tempColumn2 );
      output.setString( "tempColumn3", tempColumn3 );
   }

   public void readExternal(wt.pds.PersistentRetrieveIfc input) throws java.sql.SQLException, wt.pom.DatastoreException {
      super.readExternal( input );

      formcontent = (java.sql.Blob) input.getObject( "formcontent" );
      persistable = (wt.fc.ObjectReference) input.readObject( "persistable", persistable, wt.fc.ObjectReference.class, true );
      process = (wt.fc.ObjectReference) input.readObject( "process", process, wt.fc.ObjectReference.class, true );
      status = input.getString( "status" );
      tempColumn1 = input.getString( "tempColumn1" );
      tempColumn2 = input.getString( "tempColumn2" );
      tempColumn3 = input.getString( "tempColumn3" );
   }

   boolean readVersion6593856020316566837L( java.io.ObjectInput input, long readSerialVersionUID, boolean superDone ) throws java.io.IOException, java.lang.ClassNotFoundException {
      if ( !superDone )
         super.readExternal( input );

      formcontent = (java.sql.Blob) input.readObject();
      persistable = (wt.fc.ObjectReference) input.readObject();
      process = (wt.fc.ObjectReference) input.readObject();
      status = (java.lang.String) input.readObject();
      tempColumn1 = (java.lang.String) input.readObject();
      tempColumn2 = (java.lang.String) input.readObject();
      tempColumn3 = (java.lang.String) input.readObject();
      return true;
   }

   protected boolean readVersion( FormDataXml thisObject, java.io.ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone ) throws java.io.IOException, java.lang.ClassNotFoundException {
      boolean success = true;

      if ( readSerialVersionUID == EXTERNALIZATION_VERSION_UID )
         return readVersion6593856020316566837L( input, readSerialVersionUID, superDone );
      else
         success = readOldVersion( input, readSerialVersionUID, passThrough, superDone );

      if (input instanceof wt.pds.PDSObjectInput)
         wt.fc.EvolvableHelper.requestRewriteOfEvolvedBlobbedObject();

      return success;
   }
   protected boolean super_readVersion_FormDataXml( _FormDataXml thisObject, java.io.ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone ) throws java.io.IOException, java.lang.ClassNotFoundException {
      return super.readVersion(thisObject, input, readSerialVersionUID, passThrough, superDone);
   }

   boolean readOldVersion( java.io.ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone ) throws java.io.IOException, java.lang.ClassNotFoundException {
      throw new java.io.InvalidClassException(CLASSNAME, "Local class not compatible: stream classdesc externalizationVersionUID="+readSerialVersionUID+" local class externalizationVersionUID="+EXTERNALIZATION_VERSION_UID);
   }
}
